/* eslint-disable @typescript-eslint/explicit-module-boundary-types */
/*
 * @Author: songdengwei
 * @Date: 2020-07-21
 * @LastEditors: songdengwei
 * @LastEditTime: 2020-07-21
 * @Description:
 */
import { createI18n } from "vue-i18n";

import zh_CN from "@/language/zh_CN";
import en_US from "@/language/en_US";
import { useCommonStoreWithOut } from '@/store/modules/common';

const commonStore = useCommonStoreWithOut();

const i18n = createI18n({
    locale: commonStore.getLanguage, // 默认显示语音
    messages: { zh_CN, en_US },
});

export function setupI18n(app:any){    
    app.use(i18n);
}
